//勾股定理
export const distanceTo=(player, bullet)=> {
  let x1 = player.x;
  let y1 = player.y;
  let x2 = bullet.x;
  let y2 = bullet.y;

  return Math.sqrt(Math.pow(x1 - x2, 2) + Math.pow(y1 - y2, 2));
}